package com.example.dormmanage.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonInclude;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.time.LocalDateTime;

@Data
@ApiModel("角色实体类")
@JsonInclude(JsonInclude.Include.NON_NULL)
public class Role {
    @TableId(type = IdType.AUTO)
    @ApiModelProperty("角色id")
    private Integer roleId;

    @ApiModelProperty("角色名称")
    private String roleName;

    @ApiModelProperty("角色代码")
    private String code;

    @ApiModelProperty("角色说明")
    private String note;

    @ApiModelProperty("创建时间")
    @TableField(fill = FieldFill.INSERT,select = false)
    private LocalDateTime createTime;

    @ApiModelProperty("修改时间")
    @TableField(fill = FieldFill.INSERT_UPDATE,select = false)
    private LocalDateTime updateTime;

}
